package io.shqyang.quick.slice;

import io.shqyang.quick.ResourceTable;
import io.shqyang.quicklib.base.QuickAbilitySlice;
import ohos.agp.components.Text;

public class MainAbilitySlice extends QuickAbilitySlice {

    private Text text;
    @Override
    protected int layoutId() {
        return ResourceTable.Layout_ability_main;
    }

    @Override
    protected void initComponent() {
        text = findComponent(ResourceTable.Id_text_helloworld);
    }

    @Override
    protected void initEvent() {
        text.setClickedListener(v -> toast("一定要实现！"));
    }

    @Override
    protected void loadData(boolean isRefresh) {
        text.setText("我们联合！");
    }
}
